<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http：//www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <include file="Pub:head"/>
    <link rel="stylesheet" type="text/css" href="__PUBLIC__/Css/Style.css" />

    <script type="text/javascript">
        $(document).ready(function(){
            $("#data_list tr").dblclick(function() {
                var id=$(this).attr('id');
                //top.frmright.document.getElementById("ordernumber").value=id;
                top.frmright.document.getElementById("agreementid").value= id;

                top.frmright.document.getElementById("ordernumber").value=$("#ordernumber"+id).html();
                top.frmright.document.getElementById("customname_tr").style.display="";
                top.frmright.document.getElementById("customname_td").innerHTML = $("#customname"+id).html();

                top.frmright.document.getElementById("cname_tr").style.display="";
                top.frmright.document.getElementById("cname_td").innerHTML = $("#cname"+id).html();
                top.frmright.document.getElementById("cname").value= $("#cname"+id).html();
                top.frmright.document.getElementById("cid").value= $("#cid"+id).val();


                top.frmright.document.getElementById("feename_tr").style.display="";
                top.frmright.document.getElementById("feename_td").innerHTML = $("#businesstype"+id).html();
                top.frmright.document.getElementById("feename").value= $("#businesstype"+id).html();
                top.Dialog.close();
            });
        })

        function search()
        {
            query_ordernumber= $("#query_ordernumber").val()==""?"0":$("#query_ordernumber").val();
            var url="__URL__/searchorder/query_ordernumber/"+query_ordernumber;
            window.location.assign(url);
        }

    </script>

</head>
<body>

<div class="box1">
    <fieldset style="border-color:#999999;">
        <div class="box2" panelTitle="功能面板" id="searchPanel">
            <table>
                <tr>
                    <td style=" width:20px;"></td>
                    <td>订单号：</td>
                    <td><input id="query_ordernumber" name="query_ordernumber" value="{$query_ordernumber}" type="text"/></td>
                    <td>
                        <button type="button" onclick="search()"><span class="icon_find">查询</span></button>
                    </td>
                </tr>
            </table>
        </div>

        <table class="tableStyle" id="data_list" >
            <tr>
                <th width="">订单号</th>
                <th>客户</th>
                <th>下单日期</th>
                <th>业务类型</th>
                <th>合同类型</th>
                <th>业务员</th>
                <th>备注</th>
            </tr>
            <volist name="order_list" id="vo">
                <tr id="{$vo['id']}" >
                    <td style="display:none; ">
                        <input type="hidden" name="id" id="id{$vo['id']}" value="{$vo['id']}"  />
                        <input type="hidden" name="cid" id="cid{$vo['id']}" value="{$vo['cid']}"  />
                    </td>
                    <td id="ordernumber{$vo['id']}">{$vo['ordernumber']}</td>
                    <td id="customname{$vo['id']}">{$vo['customname']}</td>
                    <td id="orderdate{$vo['id']}"><?php if($vo['orderdate']!='0000-00-00 00:00:00') echo date('Y-m-d',strtotime($vo['orderdate'])); ?> </td>
                    <td id="businesstype{$vo['id']}">{$vo['businesstype']}</td>
                    <td id="type{$vo['id']}">
                        <switch name="vo.type">
                            <case value="1">首次签约</case>
                            <case value="2">续签</case>
                            <default />
                        </switch>
                    </td>
                    <td id="cname{$vo['id']}">
                       {$vo['cname']}
                    </td>
                    <td><span <?php if(mb_strlen($vo['remark'],'utf8')>20){ ?> title="{$vo['remark']}<?php } ?>">
                        {$vo['remark']|msubstr=0,20,'utf-8',true}</span></td>
                </tr>
            </volist>


        </table>

        <div id="TourExPage" class="page">{$page_method}</div>
    </fieldset>
</div>



</body>
</html>